//使用vue.js将数据上传到超级管理员后台界面中的活动页面

    new Vue({
        el: '#rpp',
        data: {
            rechargeList: []
        },

            created: function () {
                //为了在内部函数能使用外部函数的this对象，要给它赋值了一个名叫self的变量。
                var self = this;
                $.ajax({
                    /*本地url*/
                     url: '/server/adminRecharge/queryRechargeList',

                    //url: 'http://127.0.0.1:4396/server/adminRecharge/queryRechargeList',
                    type: 'get',
                    data: {},
                    dataType: 'json'
                }).then(function (res) {
                    console.log(res);
                    //把从json获取的数据赋值给数组
                    self.rechargeList = res.data;
                }).fail(function () {
                    console.log('失败');
                })
            },
            methods : {
				
				exit: function(){
					var adminAccout = sessionStorage.getItem("adminAccout");
					$.ajax({
						type: "get",
						url: "/server/admin/adminExit?adminAccout="+adminAccout,
						async: true,
						data: {
							
						},
						success: function(data) {
							if(window.confirm('是否退出当前账号'))
							{ 
								window.location.href = "/ComeOnProject01/html/Super/SuperAdminLogin.html"
								return true; 
							}else{
								return false;
							}
							
						}
					})
				},
            method: function(num) {
               //alert(num);
                var self = this;
                 //本地url
                 var ull = '/server/adminRecharge/queryRechargeList?pageNum=' + num;

                //var ull = 'http://127.0.0.1:4396/server/adminRecharge/queryRechargeList?pageNum=' + num;
                $.ajax({
                    url: ull,
                    type: 'get',
                    data: {},
                    dataType: 'json'
                }).then(function (res) {
                    console.log(res);
                    //把从json获取的数据赋值给数组
                    self.rechargeList = res.data;
                }).fail(function () {
                    console.log('失败');
                })
            },
        }

    });






